Skip to content

Conversation

@Rudxain
Copy link
Member

@Rudxain Rudxain commented Aug 10, 2025

  • comment-out non-deterministic tests. This is still a mystery 👀
  • un-deprecate adb_shell_command and warn in doc-comment instead
  • fix many lints
  • remove some lints (see commit message)
  • promote rustc warnings to errors, without promoting all Clippy warnings

@Rudxain Rudxain added refactor Rework of code — behaviour doesn't change ci Continuous Integration labels Aug 10, 2025
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch 5 times, most recently from da0bdbb to 9f56c02 Compare August 13, 2025 23:32
@AnonymousWP

This comment was marked as resolved.

@Rudxain

This comment was marked as resolved.

@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from 9f56c02 to 09fec11 Compare October 31, 2025 21:40
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch 2 times, most recently from 0366feb to 0ee9bbf Compare October 31, 2025 22:12
@Rudxain Rudxain changed the title ci: fix lints, disable test ci: fix lints, disable non-determ tests Oct 31, 2025
@Rudxain

This comment was marked as resolved.

@Rudxain Rudxain requested a review from Copilot October 31, 2025 22:40
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors code to improve type safety and remove unused code. The main changes focus on adding explicit lifetime parameters to Element return types, cleaning up deprecated code, and removing unused clippy lints.

Key changes:

  • Added explicit lifetime parameters ('_) to Element return types across view methods
  • Removed unused delay_hide_copy_confirmation function and inlined delay logic
  • Removed unused PickList enum and commented out unused UserInfo fields
  • Updated CI workflow to add a dedicated cargo check step with warnings as errors

Reviewed Changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/gui/widgets/package_row.rs Added explicit lifetime to Element return type
src/gui/views/settings.rs Added explicit lifetime to Element return type
src/gui/views/list.rs Added explicit lifetimes, inlined delay logic, removed unused function
src/gui/views/about.rs Added explicit lifetime to Element return type
src/gui/style.rs Removed unused PickList enum
src/gui/mod.rs Added explicit lifetime to Element return type
src/core/sync.rs Replaced deprecated attribute with warning comment, changed to_string() to clone()
src/core/config.rs Commented out non-deterministic tests
src/core/adb.rs Commented out unused UserInfo fields and methods
Cargo.toml Removed unused clippy lints and fixed indentation
.github/workflows/ci.yml Added cargo check step and updated clippy configuration

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +379 to +383
Command::perform(
// intentional delay
async { std::thread::sleep(std::time::Duration::from_secs(1)) },
|()| Message::HideCopyConfirmation,
),
Copy link

Copilot AI Oct 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using std::thread::sleep inside an async block is problematic because it blocks the executor thread, preventing other async tasks from running. Replace with tokio::time::sleep or the appropriate async sleep function for your runtime to avoid blocking the async executor.

Copilot uses AI. Check for mistakes.
Copy link
Member Author

@Rudxain Rudxain Oct 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems valid, but it's off-topic/out-of-scope for this PR.

BTW, that line was introduced in #1033, but I inlined it: 956d64a

@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from 0ee9bbf to a3cc388 Compare October 31, 2025 22:42
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from a3cc388 to f9e4344 Compare October 31, 2025 22:46
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from f9e4344 to 15fcd10 Compare October 31, 2025 23:12
this fixes `unused-doc-comments` lint warn
@Rudxain Rudxain marked this pull request as ready for review October 31, 2025 23:25
@Rudxain Rudxain requested a review from a team October 31, 2025 23:26
@AnonymousWP AnonymousWP merged commit d29e927 into main Nov 16, 2025
18 checks passed
@AnonymousWP AnonymousWP deleted the ci/fix-lints-tests branch November 16, 2025 10:39
AnonymousWP added a commit that referenced this pull request Nov 16, 2025
commit e430a6d
Author: foot fondler <[email protected]>
Date:   Sun Nov 16 13:07:24 2025 +0000

    pkg(androidtv, blackview, bluestacks, google, samsung, unisoc, waydroid): add packages (#1154)

    * Android TV; Blackview; Google; and Samsung.

    * Update uad_lists.json

    * Update uad_lists.json

    * Change removal and description

    com.android.dialer Advanced → Expert
    com.google.android.marvin.talkback Recommended → Advanced
    com.android.bluetoothmidiservice Recommended → Advanced

    * Update uad_lists.json

    * Change Google Speech Services to recommended

    * Changed some apps from Recommended to Advanced

    com.android.keyguard Recommended → Advanced
    com.huawei.ohos.inputmethod Recommended → Advanced
    com.samsung.android.net.wifi.wifiguider Recommended → Advanced

    * Delete empty line

    * Added emulator apps to close #1145

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * 16 apps added

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * 4 Japanese carrier apps

    * Update uad_lists.json

    ---------

    Co-authored-by: Anonymoussaurus <[email protected]>

commit c197541
Merge: 6594a15 337d5e5
Author: Anonymoussaurus <[email protected]>
Date:   Sun Nov 16 11:54:10 2025 +0100

    Merge pull request #1157 from Universal-Debloater-Alliance/pkg/xiaomi

    pkg(com.xiaomi.aicr): change description and removal

commit 6594a15
Author: QQ喵 <[email protected]>
Date:   Sun Nov 16 11:52:54 2025 +0100

    pkg(OnePlus) Make it explicit that com.oplus.athena kills apps (#1156)

    * Make it explicit that athena kills apps

    * Add a reference link

commit d29e927
Merge: f0655e7 f956c5d
Author: Anonymoussaurus <[email protected]>
Date:   Sun Nov 16 11:39:27 2025 +0100

    Merge pull request #1045 from Universal-Debloater-Alliance/ci/fix-lints-tests

    ci: fix lints, disable non-determ tests

commit 337d5e5
Author: Muriilo <[email protected]>
Date:   Fri Nov 14 17:46:46 2025 -0300

    pkg(Xiaomi) Changing package recommended and description

commit f956c5d
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 19:21:45 2025 -0400

    docs(main): rm redundant doc-comment

    this fixes `unused-doc-comments` lint warn

commit 15fcd10
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 18:00:28 2025 -0400

    ci(cargo-check): deny warns

commit d74a30b
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 17:31:27 2025 -0400

    Revert "ci(cargo): replace `check` by `clippy`"

    This reverts commit 38554ca.

commit ab3081b
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:29:17 2025 -0400

    style(gui/views/list): `pkg`->`p` rename, to not shadow `pkg`

commit fb131df
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:11:39 2025 -0400

    ci(adb): use `debug_assert` to not trigger `panic_in_result_fn`

commit 0dc61c8
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:03:42 2025 -0400

    refactor(adb): comment-out all `running` (user) stuff

commit 956d64a
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 18:44:02 2025 -0400

    refactor(gui/views/list): inline `delay_hide_copy_confirmation`
    fn added in 2ca3e05

commit 6a8ac88
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 18:17:42 2025 -0400

    ci: disable `test_save_changes`

commit 7477f02
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 16:04:58 2025 -0400

    refactor: rm `PickList` (unused)

commit 3fabd4a
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 16:01:24 2025 -0400

    refactor(gui/views/list): mark unused var
    lint regression at 26afc32

commit 760b21d
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 21:06:25 2025 -0400

    ci(clippy): rm some lints
    - `exit` isn't bad for apps, only for libs
    - `mem_forget` is rarely a mistake, and is trivial to catch
    - `string_to_string` is superseded by `implicit_clone`
    - `allow_attributes_without_reason` can be catched by reviewers

commit d383da8
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:21:56 2025 -0400

    ci: `cargo clippy --fix; cargo fmt`

commit 54308e1
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:18:06 2025 -0400

    ci(adb-sync): un-deprecate `adb_shell_command`; add warn to docs

commit 2729c72
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:25:03 2025 -0400

    ci: rm `config.devices.len()` assertion
AnonymousWP added a commit that referenced this pull request Nov 16, 2025
commit e430a6d
Author: foot fondler <[email protected]>
Date:   Sun Nov 16 13:07:24 2025 +0000

    pkg(androidtv, blackview, bluestacks, google, samsung, unisoc, waydroid): add packages (#1154)

    * Android TV; Blackview; Google; and Samsung.

    * Update uad_lists.json

    * Update uad_lists.json

    * Change removal and description

    com.android.dialer Advanced → Expert
    com.google.android.marvin.talkback Recommended → Advanced
    com.android.bluetoothmidiservice Recommended → Advanced

    * Update uad_lists.json

    * Change Google Speech Services to recommended

    * Changed some apps from Recommended to Advanced

    com.android.keyguard Recommended → Advanced
    com.huawei.ohos.inputmethod Recommended → Advanced
    com.samsung.android.net.wifi.wifiguider Recommended → Advanced

    * Delete empty line

    * Added emulator apps to close #1145

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * 16 apps added

    * Update uad_lists.json

    * Update uad_lists.json

    * Update uad_lists.json

    * 4 Japanese carrier apps

    * Update uad_lists.json

    ---------

    Co-authored-by: Anonymoussaurus <[email protected]>

commit c197541
Merge: 6594a15 337d5e5
Author: Anonymoussaurus <[email protected]>
Date:   Sun Nov 16 11:54:10 2025 +0100

    Merge pull request #1157 from Universal-Debloater-Alliance/pkg/xiaomi

    pkg(com.xiaomi.aicr): change description and removal

commit 6594a15
Author: QQ喵 <[email protected]>
Date:   Sun Nov 16 11:52:54 2025 +0100

    pkg(OnePlus) Make it explicit that com.oplus.athena kills apps (#1156)

    * Make it explicit that athena kills apps

    * Add a reference link

commit d29e927
Merge: f0655e7 f956c5d
Author: Anonymoussaurus <[email protected]>
Date:   Sun Nov 16 11:39:27 2025 +0100

    Merge pull request #1045 from Universal-Debloater-Alliance/ci/fix-lints-tests

    ci: fix lints, disable non-determ tests

commit 337d5e5
Author: Muriilo <[email protected]>
Date:   Fri Nov 14 17:46:46 2025 -0300

    pkg(Xiaomi) Changing package recommended and description

commit f956c5d
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 19:21:45 2025 -0400

    docs(main): rm redundant doc-comment

    this fixes `unused-doc-comments` lint warn

commit 15fcd10
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 18:00:28 2025 -0400

    ci(cargo-check): deny warns

commit d74a30b
Author: Rudxain <[email protected]>
Date:   Fri Oct 31 17:31:27 2025 -0400

    Revert "ci(cargo): replace `check` by `clippy`"

    This reverts commit 38554ca.

commit ab3081b
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:29:17 2025 -0400

    style(gui/views/list): `pkg`->`p` rename, to not shadow `pkg`

commit fb131df
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:11:39 2025 -0400

    ci(adb): use `debug_assert` to not trigger `panic_in_result_fn`

commit 0dc61c8
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 19:03:42 2025 -0400

    refactor(adb): comment-out all `running` (user) stuff

commit 956d64a
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 18:44:02 2025 -0400

    refactor(gui/views/list): inline `delay_hide_copy_confirmation`
    fn added in 2ca3e05

commit 6a8ac88
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 18:17:42 2025 -0400

    ci: disable `test_save_changes`

commit 7477f02
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 16:04:58 2025 -0400

    refactor: rm `PickList` (unused)

commit 3fabd4a
Author: Rudxain <[email protected]>
Date:   Wed Aug 13 16:01:24 2025 -0400

    refactor(gui/views/list): mark unused var
    lint regression at 26afc32

commit 760b21d
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 21:06:25 2025 -0400

    ci(clippy): rm some lints
    - `exit` isn't bad for apps, only for libs
    - `mem_forget` is rarely a mistake, and is trivial to catch
    - `string_to_string` is superseded by `implicit_clone`
    - `allow_attributes_without_reason` can be catched by reviewers

commit d383da8
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:21:56 2025 -0400

    ci: `cargo clippy --fix; cargo fmt`

commit 54308e1
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:18:06 2025 -0400

    ci(adb-sync): un-deprecate `adb_shell_command`; add warn to docs

commit 2729c72
Author: Rudxain <[email protected]>
Date:   Sat Aug 9 20:25:03 2025 -0400

    ci: rm `config.devices.len()` assertion
Merge branch 'main' into pkg/blackview
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Continuous Integration refactor Rework of code — behaviour doesn't change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants